﻿<%@ Page Title="" Language="vb" AutoEventWireup="false" MasterPageFile="~/Site.Master" CodeBehind="showAllUsers.aspx.vb" Inherits="soccer.showAllUsers" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
    <style type="text/css">
        .auto-style1 {
            font-size: medium;
        }
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="FeaturedContent" runat="server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="MainContent" runat="server">
    <p class="auto-style1">
        Here are the registered users for this site</p>
    <p class="auto-style1">
        <asp:ListView ID="ListView1" runat="server" DataSourceID="ListDataSource" GroupItemCount="3">
            <AlternatingItemTemplate>
                <td runat="server" style="background-color:#FFF8DC;">
                    <a href='Profile.aspx?uName=<%# Eval("uName")%>'>
                   <img src= '<%# Eval("uPortrait") %>' /> </a><br />Name:
                    <asp:Label ID="firstNameLabel" runat="server" Text='<%# Eval("firstName") %>' />
                    <asp:Label ID="lastNameLabel" runat="server" Text='<%# Eval("lastName") %>' />                 
                    <br />Supports :
                    <asp:Label ID="supportsTeamLabel" runat="server" Text='<%# Eval("supportsTeam") %>' />                  
                    <br />Date Profile Modified:
                    <asp:Label ID="dateModifiedLabel" runat="server" Text='<%# Eval("dateModified") %>' />
                    <br /></td>
            </AlternatingItemTemplate>
            <EditItemTemplate>
                <td runat="server" style="background-color:#008A8C;color: #FFFFFF;">firstName:
                    <asp:TextBox ID="firstNameTextBox" runat="server" Text='<%# Bind("firstName") %>' />
                    <br />lastName:
                    <asp:TextBox ID="lastNameTextBox" runat="server" Text='<%# Bind("lastName") %>' />
                    <br />supportsTeam:
                    <asp:TextBox ID="supportsTeamTextBox" runat="server" Text='<%# Bind("supportsTeam") %>' />
                    <br />uPortrait:
                    <asp:TextBox ID="uPortraitTextBox" runat="server" Text='<%# Bind("uPortrait") %>' />
                    <br />dateModified:
                    <asp:TextBox ID="dateModifiedTextBox" runat="server" Text='<%# Bind("dateModified") %>' />
                    <br />
                    <asp:Button ID="UpdateButton" runat="server" CommandName="Update" Text="Update" />
                    <br />
                    <asp:Button ID="CancelButton" runat="server" CommandName="Cancel" Text="Cancel" />
                    <br /></td>
            </EditItemTemplate>
            <EmptyDataTemplate>
                <table runat="server" style="background-color: #FFFFFF;border-collapse: collapse;border-color: #999999;border-style:none;border-width:1px;">
                    <tr>
                        <td>No data was returned.</td>
                    </tr>
                </table>
            </EmptyDataTemplate>
            <EmptyItemTemplate>
<td runat="server" />
            </EmptyItemTemplate>
            <GroupTemplate>
                <tr id="itemPlaceholderContainer" runat="server">
                    <td id="itemPlaceholder" runat="server"></td>
                </tr>
            </GroupTemplate>
            <InsertItemTemplate>
                <td runat="server" style="">firstName:
                    <asp:TextBox ID="firstNameTextBox" runat="server" Text='<%# Bind("firstName") %>' />
                    <br />lastName:
                    <asp:TextBox ID="lastNameTextBox" runat="server" Text='<%# Bind("lastName") %>' />
                    <br />supportsTeam:
                    <asp:TextBox ID="supportsTeamTextBox" runat="server" Text='<%# Bind("supportsTeam") %>' />
                    <br />uPortrait:
                    <asp:TextBox ID="uPortraitTextBox" runat="server" Text='<%# Bind("uPortrait") %>' />
                    <br />dateModified:
                    <asp:TextBox ID="dateModifiedTextBox" runat="server" Text='<%# Bind("dateModified") %>' />
                    <br />
                    <asp:Button ID="InsertButton" runat="server" CommandName="Insert" Text="Insert" />
                    <br />
                    <asp:Button ID="CancelButton" runat="server" CommandName="Cancel" Text="Clear" />
                    <br /></td>
            </InsertItemTemplate>
            <ItemTemplate>
                <td runat="server" style="background-color:#DCDCDC;color: #000000;">
                    <a href='Profile.aspx?uName=<%# Eval("uName")%>'>
                   <img src= '<%# Eval("uPortrait") %>' /> </a><br />Name:
                    <asp:Label ID="firstNameLabel" runat="server" Text='<%# Eval("firstName") %>' />
                    <asp:Label ID="lastNameLabel" runat="server" Text='<%# Eval("lastName") %>' />                 
                    <br />Supports :
                    <asp:Label ID="supportsTeamLabel" runat="server" Text='<%# Eval("supportsTeam") %>' />                  
                    <br />Date Profile Modified:
                    <asp:Label ID="dateModifiedLabel" runat="server" Text='<%# Eval("dateModified") %>' />
                    <br /></td>
            </ItemTemplate>
            <LayoutTemplate>
                <table runat="server">
                    <tr runat="server">
                        <td runat="server">
                            <table id="groupPlaceholderContainer" runat="server" border="1" style="background-color: #FFFFFF;border-collapse: collapse;border-color: #999999;border-style:none;border-width:1px;font-family: Verdana, Arial, Helvetica, sans-serif;">
                                <tr id="groupPlaceholder" runat="server">
                                </tr>
                            </table>
                        </td>
                    </tr>
                    <tr runat="server">
                        <td runat="server" style="text-align: center;background-color: #CCCCCC;font-family: Verdana, Arial, Helvetica, sans-serif;color: #000000;">
                            <asp:DataPager ID="DataPager1" runat="server" PageSize="12">
                                <Fields>
                                    <asp:NextPreviousPagerField ButtonType="Button" ShowFirstPageButton="True" ShowLastPageButton="True" />
                                </Fields>
                            </asp:DataPager>
                        </td>
                    </tr>
                </table>
            </LayoutTemplate>
            <SelectedItemTemplate>
                <td runat="server" style="background-color:#008A8C;font-weight: bold;color: #FFFFFF;">firstName:
                    <asp:Label ID="firstNameLabel" runat="server" Text='<%# Eval("firstName") %>' />
                    <br />lastName:
                    <asp:Label ID="lastNameLabel" runat="server" Text='<%# Eval("lastName") %>' />
                    <br />supportsTeam:
                    <asp:Label ID="supportsTeamLabel" runat="server" Text='<%# Eval("supportsTeam") %>' />
                    <br />uPortrait:
                    <asp:Label ID="uPortraitLabel" runat="server" Text='<%# Eval("uPortrait") %>' />
                    <br />dateModified:
                    <asp:Label ID="dateModifiedLabel" runat="server" Text='<%# Eval("dateModified") %>' />
                    <br /></td>
            </SelectedItemTemplate>
        </asp:ListView>
        <asp:SqlDataSource ID="ListDataSource" runat="server" ConnectionString="<%$ ConnectionStrings:SoccerConnectionString %>" ProviderName="<%$ ConnectionStrings:SoccerConnectionString.ProviderName %>" SelectCommand="SELECT [firstName], [lastName], [supportsTeam], [uPortrait], [dateModified],[uName] FROM [SoccerProfile]"></asp:SqlDataSource>
    </p>
</asp:Content>
